package com.example.tsbs.config;

import lombok.Data;

@Data
public class Result<T> {
    private String log;
    private T data;

    public Result(String log) {
        this.log = log;
    }

    public Result() {
    }
    public static <T> Result<T> success() {
        return new Result<>("成功");
    }
    public static <T> Result<T> success(String log) {
        return new Result<>(log);
    }

    public static <T> Result<T> info(String log) {
        return new Result<>(log);
    }

    public static <T> Result<T> error(String log) {
        return new Result<>(log);
    }

}
